package com.fs.mapper;

import com.fs.pojo.SysAdminToken;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;

/**
 * 管理员登录token表
 */
@Mapper
public interface SysAdminTokenMapper extends BaseMapper<SysAdminToken> {

    @Select("select * from sys_admin_token where user_id=#{userId}")
    SysAdminToken findByUserId(Integer userId);

    @Select("select * from sys_admin_token where token=#{accessToken}")
    SysAdminToken findByToken(String accessToken);
}
